Field of the Invention
The invention relates in general to a frequency divider and a control method thereof.
Description of the Related Art
The frequency divider of the prior art includes a phase selector which switches the output signal from an input signal to another input signal. However, the switching process can only be performed when the input signals are at low level or high level both before and after the switching process. Otherwise, glitches will occur to the output signal of the frequency divider and cause error to the frequency generated by the frequency divider. Thus, the frequency divider of the prior art can perform the switching process only during the period when the input signals have the same level both before and after the switching process (the phase difference between two input signals is defined as a period). According to one method provided for resolving the above problems, the input signal with triangular wave is used, such that the input signal gradually switches to high level from low level, and the glitches generated when the input signals have different levels will have a smaller amplitude. According to another method, the phase of the next input signal of the target input signal is detected, such that the switching process is performed only when the phase of the target input signal and the phase of the current input signal have the same level. However, the above two methods cannot completely avoid the occurrence of glitches. During the operation of the switching process, the frequency divider is still subject to the condition that the two input signals must have the same level. Therefore, it has become a prominent task for the industries to provide a method to avoid the occurrence of glitch.